// 房产相关类型定义

export interface Property {
  id: string
  propertyCod: string
  building: string
  room: string
  typeId: 'residential' | 'commercial' | 'parking'
  area: number
  structure: string
  owner: string
  contact: string
  status: 'available' | 'occupied' | 'maintenance' | 'sold'
  createdAt?: string
  updatedAt?: string
}

export interface PropertyStats {
  totalProperties: number
  availableProperties: number
  occupiedProperties: number
  maintenanceProperties: number
  soldProperties?: number
}

export interface SearchParams {
  propertyCode?: string
  building?: string
  propertyStatus?: string
  pageNum?: number
  pageSize?: number
}

export interface ApiResponse<T = any> {
  code: number
  message: string
  data: T
  total?: number
}

export interface PaginatedResponse<T> {
  data: T[]
  total: number
  page: number
  size: number
  totalPages: number
}